<?php /* Smarty version 2.6.18, created on 2016-12-09 14:35:10
         compiled from grade/m.graduate.history.tpl.php */ ?>
<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "m.index.header.tpl.php", 'smarty_include_vars' => array()));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>
<!--头部 end--> 
<!--主体部分-->
<form name="myform" action="" method="get">
<div class="container" style="margin-top:70px;"> 
  
  <!-- <div class="row" style="margin-right:10%;">
    <div  class="col-xs-sm  text-right" > <a class="btn btn-primary" href="superior_notice_add.html" style="width:30%">增加</a></div>
  </div>
   -->
  <div class="row" style="margin-top:10px;">
    <div class="col-sm-12 distance" >
      <div class="form-group">
        <label for="" class="col-sm-2 control-label">姓名:</label>
        <div class="col-sm-10">
          <input type="text" class="form-control" name="graduate_name" value="<?php echo $this->_tpl_vars['graduate_name']; ?>
">
        </div>
      </div>
    </div>
    <div class="col-sm-12 distance" >
      <div class="form-group">
        <label for="" class="col-sm-2 control-label">学籍号:</label>
        <div class="col-sm-10">
          <input type="text" class="form-control" name="graduate_num" value="<?php echo $this->_tpl_vars['graduate_num']; ?>
">
        </div>
      </div>
    </div>
    <div class="col-xs-12 distance hierarchy2">
      <div class="form-group  text-center" style="padding-top:0px;">
	    <input type="hidden" name="a" value="graduate.history">
        <button type="submit" class="btn btn-success absolutely ">搜索</button>
      </div>
    </div>
  </div>
  </form>
  <div class="row" style="margin-top:15px;margin-left:1px; margin-right:1px;" >
  <?php $_from = $this->_tpl_vars['graduate_lists']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
    foreach ($_from as $this->_tpl_vars['key'] => $this->_tpl_vars['value']):
?>
    <table class="table table-striped table-bordered text-center"  id="middles" >
      <tr>
        <td>学号</td>
        <td><?php echo $this->_tpl_vars['value']['graduate_no']; ?>
</td>
      </tr>
      <tr>
        <td>姓名</td>
        <td><?php echo $this->_tpl_vars['value']['graduate_name']; ?>
</td>
      </tr>
      <tr>
        <td>学籍号</td>
        <td><?php echo $this->_tpl_vars['value']['graduate_num']; ?>
</td>
      </tr>
      <tr>
        <td>毕业证书号</td>
        <td><?php echo $this->_tpl_vars['value']['graduate_certificate']; ?>
</td>
      </tr>
      <tr>
        <td>毕业类型</td>
        <td><?php echo $this->_tpl_vars['value']['graduate_type']; ?>
</td>
      </tr>
      <tr>
        <td>就读学校</td>
        <td><?php echo $this->_tpl_vars['value']['graduate_school']; ?>
</td>
      </tr>
	  <?php $_from = $this->_tpl_vars['value']['graduate_na']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
    foreach ($_from as $this->_tpl_vars['ke'] => $this->_tpl_vars['va']):
?>
      <tr>
		
			<td><?php echo $this->_tpl_vars['ke']; ?>
</td>
		
        
			<td><?php echo $this->_tpl_vars['va']; ?>
</td>
		
      </tr>
	  <?php endforeach; endif; unset($_from); ?>
      <tr>
        <td>总分</td>
        <td><?php echo $this->_tpl_vars['value']['graduate_count']; ?>
</td>
      </tr>
      <tr>
        <td>毕业评语</td>
        <td><?php echo $this->_tpl_vars['value']['graduate_content']; ?>
</td>
      </tr>
      <tr>
        <td>备注</td>
        <td><?php echo $this->_tpl_vars['value']['graduate_remark']; ?>
</td>
      </tr>
    </table>
	<?php endforeach; endif; unset($_from); ?>
  </div>
</div>
<!--container  end--> 
<!--主体部分  end--> 
<!--底部-->
<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => "m.index.footer.tpl.php", 'smarty_include_vars' => array()));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?> 
<script type="text/javascript">
        $(document).ready(function () {
            $("#grade_id").change(function () {		
                if ($(this).val() == "-1") {
					$("#industr").remove(); return; 
					}
                else {
			var timestamp = new Date().getTime();
			$.ajax({
			url:"index.php?a=student.gradelistjson",
			type:"get",
			data: "grade_id=" + $("#grade_id").find("option:selected").val() + "&timestamp=" + timestamp,
			dataType:"json",
			success:function(msg){
			   
                            //实例2个字符串变量来拼接下拉列表
                            var industr = "";
                            //使用jquery解析json中的数据
                            $.each(msg, function (n, value) {
                                industr += ("<option value=\"" + value.class_id + "\">" + value.class_name);
                                industr += ("</option>");
                            });

                            $("#class_id").html(industr);			   			   
			}
			});					

                }

            });

        });
</script>